<?php
/**
 * Created by PhpStorm.
 * User: admin
 * Date: 2021.3.19
 * Time: 16:23
 */

interface A {

}

class B implements  A {

}

abstract class C {

}

class D extends  C {

}

class E {

}

$classArr = [
    'A','B','C','D','E'
];

foreach ($classArr as $v) {
    $reflector = new ReflectionClass($v);
    echo "Is {$v} instantiable \r\n";
    var_dump($reflector->isInstantiable());
}

// 接口，抽象类不能实例化